Feature/Fix: Adapt rollout snapshots for lineage accounting#2141
Feature/Fix: Adapt rollout snapshots for lineage accounting#2141iam-brain wants to merge 2 commits into
Conversation
|
Codex review: needs real behavior proof before merge. Reviewed July 13, 2026, 9:08 PM ET / July 14, 2026, 01:08 UTC. Summary Reproducibility: not applicable. as a standalone bug reproduction: this draft is a shadow architecture adapter, while the underlying accounting problem is represented by the canonical issue and existing sanitized fixtures. Review metrics: 3 noteworthy metrics.
Root-cause cluster Members:
Proposal only: this assessment does not dispatch repair, suppress jobs, mutate sibling items, close, or merge anything. Merge readiness Overall follows the weaker of proof and patch quality, so missing proof can cap an otherwise strong patch. Rank-up moves:
Proof guidance:
Risk before merge
Maintainer options:
Next step before merge
Security Review detailsBest possible solution: Review and land the shadow-ledger foundation first, then require a redacted real-rollout initial and cached repeat-scan transcript showing correct document identity, preserved cancellation, unchanged published totals, and acceptable one-time cache rebuilding. Do we have a high-confidence way to reproduce the issue? Not applicable as a standalone bug reproduction: this draft is a shadow architecture adapter, while the underlying accounting problem is represented by the canonical issue and existing sanitized fixtures. Is this the best way to solve the issue? Unclear pending stack and runtime proof. Reusing the existing cancellation-aware scan is a narrow maintainable approach, but its real upgrade and accounting behavior must be demonstrated before acceptance. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning high; reviewed against 0437067deaa8. Label changesLabel changes:
Label justifications:
Evidence reviewedWhat I checked:
Likely related people:
What the crustacean ranks mean
Shiny media proof means a screenshot, video, or linked artifact directly shows the changed behavior. Runtime, network, CSP, and security claims still need visible diagnostics. How this review workflow works
|
|
Superseded by the consolidated four-PR review stack. This slice is now included in #2155; closing this draft to keep the upstream review surface manageable. |
Stack dependency
This is slice 2 of 15. It follows Feature/Fix: Add a shadow lineage ledger for Codex token accounting; review and merge that PR first.
Summary
Adds the first scanner adapter for the planned lineage-ledger rearchitecture. The existing fast, cancellation-aware JSONL scan now produces raw complete token observations alongside its legacy cumulative snapshots, then adapts that parsed evidence into
CodexLineageLedger.Documentvalues.This is a stacked PR on top of the shadow ledger foundation. It does not run the ledger from production discovery and does not change published totals.
Details
CostUsageJsonlpass; no second rollout parser(last_token_usage, total_token_usage)observationsValidation
swift test --filter CodexLineageLedgerTests— 9 tests passedmake checkSDKROOT=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX26.5.sdk make test— all 639 selections passed across 54 groups with no retries or timeoutsTracks Feed the fast parser into typed rollout documents.
Related investigation: steipete/CodexBar#2037.